//---------------------------------------------------------------------------

#ifndef TLineH
#define TLineH
#include "vcl.h"
#include "TArea.h"
#include "TPointMark.h"
enum TWeightType { wtLength, wtWeight };
//---------------------------------------------------------------------------
class TLine {
  public:
    TPen *Pen;
    TPointMark *BeginPM;
    TPointMark *EndPM;
    TArea *Area;
    TCanvas *Canvas;
    TText *Text;
    TWeightType WT;

    int Weight;
    bool Orient;
    bool Visible;
    bool MarkDir;

    __fastcall TLine(TCanvas *_Canvas, TArea *_Area);
    __fastcall ~TLine();
    void __fastcall Draw();
    void __fastcall Assign(TLine * _Line, bool Points);
    void __fastcall ToFile(TMemo * Memo);
    void __fastcall FromFile(int & i, TMemo * Memo);
    double __fastcall GetLength();
    __fastcall DrawArrow();
  private:
    double x1;
    double y1;
    double x2;
    double y2;
    void __fastcall DrawLine();

};

#endif
